/* ============================================
   Language Switcher & Telugu Font Support Styles
   ============================================ */

/* Import Telugu Font from Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+Telugu:wght@400;500;600;700&display=swap');

/* Telugu Language Body Class */
.telugu-lang {
  font-family: 'Noto Sans Telugu', Arial, sans-serif !important;
}

.telugu-lang * {
  font-family: inherit;
}

/* Ensure proper line height for Telugu text */
.telugu-lang p,
.telugu-lang span,
.telugu-lang label,
.telugu-lang a,
.telugu-lang button,
.telugu-lang h1,
.telugu-lang h2,
.telugu-lang h3,
.telugu-lang h4,
.telugu-lang h5,
.telugu-lang h6,
.telugu-lang li,
.telugu-lang td,
.telugu-lang th {
  line-height: 1.8;
}

/* ============================================
   Language Switcher Component
   ============================================ */

.language-switcher {
  position: relative;
  z-index: 1000;
  flex-shrink: 0;
  white-space: nowrap;
}

.lang-switch-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 8px;
  color: #fff;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}

.lang-switch-btn:hover {
  background: rgba(255, 255, 255, 0.25);
  border-color: rgba(255, 255, 255, 0.5);
}

.lang-icon {
  font-size: 16px;
}

.lang-text {
  font-weight: 600;
  min-width: 24px;
  text-align: center;
}

.lang-arrow {
  font-size: 10px;
  transition: transform 0.2s ease;
}

.lang-dropdown.show + .lang-switch-btn .lang-arrow,
.lang-switch-btn:focus .lang-arrow {
  transform: rotate(180deg);
}

/* Language Dropdown */
.lang-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 180px;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all 0.2s ease;
  overflow: hidden;
  z-index: 1001;
}

.lang-dropdown.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.lang-option {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 14px 16px;
  background: transparent;
  border: none;
  color: #333;
  font-size: 14px;
  font-weight: 500;
  text-align: left;
  cursor: pointer;
  transition: all 0.15s ease;
}

.lang-option:hover {
  background: #f0f4ff;
}

.lang-option.active {
  background: #e8f0ff;
  color: #0052CC;
}

.lang-option.active::after {
  content: '✓';
  margin-left: auto;
  color: #0052CC;
  font-weight: bold;
}

.lang-flag {
  font-size: 20px;
}

/* ============================================
   Floating Language Switcher (for login/registration pages)
   ============================================ */

.floating-lang-switcher {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 9999;
}

.floating-lang-switcher .lang-switch-btn {
  background: #0052CC;
  border-color: #0052CC;
  box-shadow: 0 4px 12px rgba(0, 82, 204, 0.3);
}

.floating-lang-switcher .lang-switch-btn:hover {
  background: #003d99;
  border-color: #003d99;
}

/* ============================================
   Telugu-specific form adjustments
   ============================================ */

.telugu-lang input,
.telugu-lang textarea,
.telugu-lang select {
  font-family: 'Noto Sans Telugu', Arial, sans-serif;
  font-size: 14px;
}

.telugu-lang input::placeholder,
.telugu-lang textarea::placeholder {
  font-family: 'Noto Sans Telugu', Arial, sans-serif;
}

/* Button text adjustments for Telugu */
.telugu-lang .register-btn,
.telugu-lang .submit-btn,
.telugu-lang .save-btn,
.telugu-lang .btn-primary {
  font-size: 15px;
  padding: 12px 24px;
}

/* Navigation link adjustments for Telugu */
.telugu-lang .nav-link {
  font-size: 14px;
  padding: 12px 20px;
}

/* Feature card title adjustments */
.telugu-lang .feature-title {
  font-size: 16px;
  line-height: 1.6;
}

.telugu-lang .feature-desc {
  font-size: 13px;
  line-height: 1.7;
}

/* Header title adjustments */
.telugu-lang .portal-title {
  font-size: 22px;
}

.telugu-lang .portal-tagline {
  font-size: 12px;
}

/* Page headers */
.telugu-lang .page-title,
.telugu-lang .settings-title {
  font-size: 24px;
}

.telugu-lang .page-subtitle,
.telugu-lang .settings-subtitle {
  font-size: 14px;
}

/* Hero section */
.telugu-lang .hero-title {
  font-size: 36px;
  line-height: 1.4;
}

.telugu-lang .hero-subtitle {
  font-size: 18px;
}

.telugu-lang .hero-description {
  font-size: 16px;
}

/* Welcome section */
.telugu-lang .welcome-title {
  font-size: 22px;
}

.telugu-lang .welcome-text {
  font-size: 15px;
  line-height: 1.8;
}

/* Footer adjustments */
.telugu-lang .footer-title {
  font-size: 18px;
}

.telugu-lang .footer-links a {
  font-size: 13px;
}

/* Settings menu buttons */
.telugu-lang .settings-btn {
  font-size: 14px;
}

/* Form labels */
.telugu-lang label {
  font-size: 14px;
  margin-bottom: 6px;
}

/* Contact page */
.telugu-lang .person-name {
  font-size: 16px;
}

.telugu-lang .person-role span {
  font-size: 13px;
}

/* Announcements */
.telugu-lang .announcement-title {
  font-size: 17px;
}

.telugu-lang .announcement-desc {
  font-size: 14px;
  line-height: 1.8;
}

/* Q&A */
.telugu-lang .faq-question {
  font-size: 15px;
}

.telugu-lang .faq-answer {
  font-size: 14px;
  line-height: 1.8;
}

/* Calendar */
.telugu-lang .month-year-display {
  font-size: 18px;
}

.telugu-lang .today-btn {
  font-size: 13px;
}

/* ============================================
   Responsive adjustments
   ============================================ */

@media (max-width: 768px) {
  .lang-switch-btn {
    padding: 6px 10px;
    font-size: 13px;
  }

  .lang-text {
    min-width: 20px;
  }

  .lang-icon {
    font-size: 14px;
  }

  .lang-dropdown {
    min-width: 160px;
    right: -10px;
  }

  .lang-option {
    padding: 12px 14px;
    font-size: 13px;
  }

  .floating-lang-switcher {
    top: 10px;
    right: 10px;
  }

  .telugu-lang .hero-title {
    font-size: 26px;
  }

  .telugu-lang .hero-subtitle {
    font-size: 15px;
  }

  .telugu-lang .welcome-title {
    font-size: 18px;
  }

  .telugu-lang .page-title {
    font-size: 20px;
  }
}

@media (max-width: 480px) {
  .lang-switch-btn {
    padding: 5px 8px;
  }

  .lang-arrow {
    display: none;
  }

  .telugu-lang .hero-title {
    font-size: 22px;
  }

  .telugu-lang .feature-title {
    font-size: 14px;
  }

  .telugu-lang .nav-link {
    font-size: 13px;
  }
}

/* ============================================
   Print styles
   ============================================ */

@media print {
  .language-switcher,
  .floating-lang-switcher {
    display: none !important;
  }
}
